package br.ufal.tci.nexos.arcolive.command;

import br.ufal.tci.nexos.arcolive.exception.ArCoLIVECannotProcessCommandException;
import br.ufal.tci.nexos.arcolive.service.connection.ConnectionRequest;

public abstract class ArCoLIVEClientCommand {

	protected ConnectionRequest request;
	
	public ArCoLIVEClientCommand(ConnectionRequest request) {
		this.request = request;
	}
	
	public ArCoLIVECommandResult execute() throws ArCoLIVECannotProcessCommandException {
		return this.executeImpl();
	}
	
	public ArCoLIVECommandResult executeNoException() {
		return this.executeImpl();
	}
	
	protected abstract ArCoLIVECommandResult executeImpl();

}